-- GENERATED SPELL FOR [Wandering Shadow] --


function spell0_30842(pUnit, Event) --@Chilling Touch,n/a--
pUnit:FullCastSpellOnTarget(38240,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30842', 6329, 1)
end

function spell1_30842(pUnit, Event) --@Curse of Weakness,n/a--
pUnit:FullCastSpellOnTarget(18267,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30842', 30284, 1)
end

function Sorts_30842(pUnit, Event)
local choix_sorts_30842 = math.random(0, 1)
if choix_sorts_30842 == 0 then
pUnit:RegisterEvent('spell0_30842', 1, 1)
end
if choix_sorts_30842 == 1 then
pUnit:RegisterEvent('spell1_30842', 1, 1)
end
end

function mob30842_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_30842', math.random(1500, 3000), 1)
end

function mob30842_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30842_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30842_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(30842, 1, 'mob30842_Action')
RegisterUnitEvent(30842, 2, 'mob30842_Leave')
RegisterUnitEvent(30842, 3, 'mob30842_Kill')
RegisterUnitEvent(30842, 4, 'mob30842_Die')
